import requests

files = {'file': open('background.png', 'rb')}

url = 'https://httpbin.org/post'
response = requests.post(url, files=files)
print(response.text)